﻿/*-----------------------------------------------------------------------------------------------
// Copyright (C) yangrongfeng 
//
// 文件名：        SysUserModel.cs
// 文件功能描述：   系统用户Model
//
// 
// 创建标识：       庞永飞  2016-04-21
//
// 修改标识：
// 修改描述：
//
// 备注：	
// 				
//-----------------------------------------------------------------------------------------------*/

using HYBY.Task.DataEntity;
using HYBY.WebFrameWork.Mvc;
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace Web.Models {

    public class SysUserModel : BaseViewModel {

        [Display(Name = "用户编码")]
        [Required]
        public Int32 UserID {
            get;
            set;
        }

        [Display(Name = "用户姓名")]
        public String UserName {
            get;
            set;
        }

        [Display(Name = "登录账号")]
        public String UserAccount {
            get;
            set;
        }

        [Display(Name = "登录口令")]
        [DataType(DataType.Password)]
        public String Password {
            get;
            set;
        }

        [Display(Name = "所属部门")]
        [Required]
        public Int32 DeptID {
            get;
            set;
        }

        [Display(Name = "职  务")]
        public String Duty {
            get;
            set;
        }

        [Display(Name = "联系电话")]
        public String Telphone {
            get;
            set;
        }

        [Display(Name = "移动电话")]
        public String Mobile {
            get;
            set;
        }

        [Display(Name = "通讯地址")]
        public String Address {
            get;
            set;
        }

        public List<SelectListItem> Departments{
            get {
                List<SelectListItem> Result = new List<SelectListItem>();
                Result.Add(new SelectListItem { Value = "1", Text = "网络部" });
                Result.Add(new SelectListItem { Value = "2", Text = "商务部" });
                Result.Add(new SelectListItem { Value = "3", Text = "主案部" });
                return Result;
            }
        }
    }

    public class SysUserListModel : BaseListViewModel<SysUserEntity> {
    }
}